#!/bin/bash
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
cd $DIR


sudo docker-compose -f "./docker/docker-compose.yml" exec app_wwwroot php /app/wwwroot/think migrate:rollback -t 0
sudo docker-compose -f "./docker/docker-compose.yml" exec app_wwwroot php /app/wwwroot/think migrate:run
sudo docker-compose -f "./docker/docker-compose.yml" exec app_wwwroot php /app/wwwroot/think seed:run
